import Vue from 'vue'
import App from './App.vue'
import router from './router'
Vue.config.productionTip = false
import Vant from 'vant';
import 'vant/lib/index.css';

Vue.use(Vant);

// 引入css
import "./assets/css/reset.css"
import "animate.css"
import "./assets/css/iconfont.css"


// 引入js
import "./assets/js/rem.js"


router.beforeEach((to,from,next)=>{
  if(to.path=="/register"||to.path=="/login"){
    next()
    
  }else if(localStorage.getItem("user")){
    next()
  }
  next()
})

new Vue({
  router,
  render: h => h(App)
}).$mount('#app')
